<?php
	require_once("../inc/function.php");
	
function NewUser($row)
{	
	$first_name = strip_tags($row['first_name']);
	$last_name = strip_tags($row['last_name']);
	$email = strip_tags($row['email']);
	$password = md5(strip_tags($row['password']));
	$date = date("Y:m:d H:m:s");
	$keyword_id = 3;

	if((strlen($first_name) > 0) && (strlen($last_name) > 0))
	{		
		$conn = GetConnection();
		$conn->query("INSERT INTO Customer  Values (NULL,'$date','CURRENT_TIMESTAMP','$first_name','$last_name', '$email' , '$password', '$keyword_id')");
		$conn->close();		
	}
	else 
	{
		die("You need to enter a customer name.");
	}
}
?>